﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<Prodma.DataAccess.Models.ViewModels.UrunlerVm>" %>
<%--<style>
#watermark_box {
position:relative;
display:block;
}
img.watermark {
position: absolute;
width:300px;
height:330px;
top: 0;
right:0;
left: 0;
} 

</style>--%>
<script src="../../../Scripts/jquery.ad-gallery.js" type="text/javascript"></script>
<script src="../../../Scripts/jquery.ad-gallery.pack.js" type="text/javascript"></script>
<script src="../../../Scripts/jquery-1.4.1.min.js" type="text/javascript"></script>
<link href="../../../Styles/jquery.ad-gallery.css" rel="stylesheet" type="text/css" />
<script type="text/javascript">
    $(function () {
        $('img.image1').data('ad-desc', 'Whoa! This description is set through elm.data("ad-desc") instead of using the longdesc attribute.<br>And it contains <strong>H</strong>ow <strong>T</strong>o <strong>M</strong>eet <strong>L</strong>adies... <em>What?</em> That aint what HTML stands for? Man...');
        $('img.image1').data('ad-title', 'Title through $.data');
        $('img.image4').data('ad-desc', 'This image is wider than the wrapper, so it has been scaled down');
        $('img.image5').data('ad-desc', 'This image is higher than the wrapper, so it has been scaled down');
        var galleries = $('.ad-gallery').adGallery();
        $('#switch-effect').change(
function () {
    galleries[0].settings.effect = $(this).val();
    return false;
}
);
        $('#toggle-slideshow').click(
function () {
    galleries[0].slideshow.toggle();
    return false;
}
);
        $('#toggle-description').click(
function () {
    if (!galleries[0].settings.description_wrapper) {
        galleries[0].settings.description_wrapper = $('#descriptions');
    } else {
        galleries[0].settings.description_wrapper = false;
    }
    return false;
}
);
    }); 
</script>
<div class="productDetailNameContainer">
    <%Prodma.DataAccess.Models.ViewModels.UrunlerVm urun = ViewData.Model; %>
    <%=urun.UrunAdi %>
    <% IList<Prodma.DataAccess.Database.Tb_FotoGaleri> fotoGaleri = Prodma.DataAccess.DataService.ListService.ImageList.GetPhotos(urun.ID); %>
    <% IList<Prodma.DataAccess.Database.Tb_AracFoto> aracFoto = Prodma.DataAccess.DataService.ListService.ImageList.GetAracFoto(urun.ID); %>
</div>
<div class="productDetailContainer">
    <div class="ad-gallery" id="gallery">
        <div class="ad-image-wrapper" style="background-color:White;">
            <img class="ad-loader" src="/Images/loader.gif" style="display: none;">
            <div class="ad-next" style="height: 400px;">
                <div class="ad-next-image" style="opacity: 0.7; display: none;"></div>
            </div>
            <div class="ad-prev" style="height: 400px;">
                <div class="ad-prev-image" style="opacity: 0.7; display: none;"></div>
            </div>
            <div class="ad-image" style="width: 600px; height: 400px; ">
                <img width="600" height="400" >
                <p class="ad-image-description" style="width: 586px; bottom: 0px;">
                </p>
            </div>
            <%--<div id="watermark_box">
                <img src="<%=urun.FotoURL %>" alt="Your image"/>
                <img src="../../../Styles/images/1297842.png" class="watermark" alt="Watermark image" />
            </div> --%>
        </div>
        <div class="ad-nav">
            <div class="ad-back" style="opacity: 0.6;"></div>
            <div class="ad-thumbs">
                <ul class="ad-thumb-list" style="width: 1454px;">
                <% foreach (Prodma.DataAccess.Database.Tb_FotoGaleri item in fotoGaleri)
                   {%>
                      <li>
                        <a class="ad-thumb3" href="<%= item.FotoURL %>">
                            <img class="image3" title="<%=item.Aciklama %>" src="<%=item.ThumbURL %>" style="opacity: 0.7;">
                        </a>
                    </li> 
                  <% } %>

                  <% foreach (Prodma.DataAccess.Database.Tb_AracFoto item in aracFoto)
                   {%>
                      <li>
                        <a class="ad-thumb3" href="<%= item.FotoUrl %>">
                            <img class="image3" title="<%=item.Aciklama %>" src="<%=item.ThumbUrl %>" style="opacity: 0.7;">
                        </a>
                    </li> 
                  <% } %>
                    
                </ul>
            </div>
            <div class="ad-forward" style="opacity: 0.6;"></div>
        </div>
    </div>
    <div class="productDetailPricesContainer">
        <div class="productDetailPricesTop">
            <div class="productDetailPricesTopRow">
                <div class="productDetailPricesTopRowLeft">Fiyat</div>
                <div class="productDetailPricesTopRowRight">:<%=urun.Fiyat %></div>
            </div>
            <div class="productDetailPricesTopRow">
                <div class="productDetailPricesTopRowLeft">KDV Dahil</div>
                <div class="productDetailPricesTopRowRight">:<%=urun.Fiyat  %></div>
            </div>
            <div class="productDetailPricesTopRow">
                <div class="productDetailPricesTopRowLeft">Havale/EFT</div>
                <div class="productDetailPricesTopRowRight">:<%=urun.Fiyat %></div>
            </div>
            <div class="productDetailPricesTopRow">
                <div class="productDetailPricesTopRowLeft">Hacim</div>
                <div class="productDetailPricesTopRowRight">:<%=urun.Hacim %></div>
            </div>
            <div class="productDetailPricesTopRow">
                <div class="productDetailPricesTopRowLeft">Ağırlık</div>
                <div class="productDetailPricesTopRowRight">:<%=urun.Agirlik %></div>
            </div>
            <div class="productDetailPricesTopRow">
                Bu ürünün ortalama teslimat süresi
            </div>
        </div>
        <div class="productDetailPricesBottom">
            <div class="productDetailPricesBottom">
                <div><input type="text" maxlength="2" value="1" id='quantity' name='quantity'
                              class="detailSectionControl" style="width: 25px" />
                <input type="submit" value="Sepete Ekle" class="addChartButton" onclick="formSubmit(<%=urun.ID %>)"/></div>
            </div>
        </div>
    </div>
</div>
